#include "stdafx.h"
#include "QQ2Bing.h"


CodeMood::QQ2Bing::QQ2Bing(string infilename) : Translator(infilename)
{
}


CodeMood::QQ2Bing::QQ2Bing(string infilename, string outfilename) : Translator(infilename, outfilename)
{
}


CodeMood::QQ2Bing::~QQ2Bing()
{
}


void CodeMood::QQ2Bing::translate()
{
	char line[MAX_LINE_LENGTH];
	string::size_type secondspace;
	while (spif_->getline(line, MAX_LINE_LENGTH)) {
		string linestr(line);
		secondspace = linestr.find(" ", linestr.find(" ") + 1);
		*spof_.get() << "'" << linestr.substr(0, secondspace) << "\n";	// No flush for I/O efficiency
	}
}
